import Vue from "vue"
import VueRouter from "vue-router"
import MyGoodsList from '@/view/MyGoodsList.vue'
import MyGoodsSearch from '@/view/MyGoodsSearch.vue'
import MyUserInfo from '@/view/MyUserInfo.vue'
import A from '@/view/多重嵌套/A.vue'
import B from '@/view/多重嵌套/B.vue'
import C from '@/view/多重嵌套/C.vue'
import D from '@/view/多重嵌套/D.vue'
import CC from '@/view/多重嵌套/CC.vue'
import DD from '@/view/多重嵌套/DD.vue'
import FF from '@/view/多重嵌套/FF.vue'
import GG from '@/view/多重嵌套/GG.vue'
import HH from '@/view/多重嵌套/HH.vue'
Vue.use(VueRouter)
const routes = [
    // {
    //     path: '/',
    //     redirect: '/mygoodslist'
    // },
    {
        path: '/mygoodslist',
        component: MyGoodsList,
        name: 'MyGoodsList'
    },
    {
        path: '/mygoodssearch',
        component: MyGoodsSearch,
        name: 'MyGoodsSearch'
    },
    {
        path: '/myuserinfo',
        component: MyUserInfo,
        name: 'MyUserInfo'
    },
    {
        path: '/a',
        component: A,
    },   {
        path: '/b',
        component: B,
    },   {
        path: '/c',
        component: C,
        children:[
           {
            path: 'cc',
            component: CC,
            name:'CC'
           },
           {
            path: 'dd',
            component: DD,
            name:'DD'
           },
           {
            path: 'ff',
            component: FF,
            name:'FF',
            children:[
                {
                    path: 'gg',
                    component: GG,
                },
                {
                    path: 'hh',
                    component: HH,
                }
            ]
           }
        ]
    },   {
        path: '/d',
        component: D,
    },
]
const router =new VueRouter({
    routes,
})
export default router